﻿<%@ page language="java" pageEncoding="utf-8"%>
<%@page import="orest.back.membermanage.RegisterUserHandler"%>
<%@page import="net.ssta.core.db.RecordSet"%>
<%@page import="net.ssta.core.db.Record"%>
<%@page import="net.ssta.core.web.HTMLGenerator"%>
<%@page import="orest.back.membermanage.RegisterUserHandler"%>
<%@page import="net.ssta.common.LoginUser"%>


<%
	String path = request.getContextPath();
	String userId=LoginUser.getUserId();
	RegisterUserHandler handler=new RegisterUserHandler();
	Record r=handler.getUserUpgradeInfo(userId);
    
%>



<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>

    <META http-equiv=Content-Type content="text/html; charset=utf-8" />
    <META http-equiv=x-ua-compatible content=ie=7 />
    <META content="MSHTML 6.00.6000.17107" name=GENERATOR />
    <link href="<%=path%>/common1/css/layout.css" rel="stylesheet" type="text/css" />
	<link href="<%=path%>/common1/css/user.css" rel="stylesheet" type="text/css" />
    <script type="text/javascript" src="<%=path%>/includes/styleBase/js/jquery.js"></script>
 
<title>用户升级</title>
 
 <script>
    function chooseOne(cb){  
         var obj = document.getElementsByName("FKTYPE");  
         for (i=0; i<obj.length; i++){  
             if (obj[i]!=cb) obj[i].checked = false;  
              else obj[i].checked = true;  

         }  

     }  
     
 </script>
 
 
 
</head>
<body>

<%@include file="../../common1/toplogin.jsp"%>    
<%@include file="../../common1/topbanner.jsp"%> 
<%@include file="../../common1/topmenu.jsp"%> 



<div id="contentmain">
 
<%@include file="../include/baseConfig.jsp"%> 



 <div id="content_right">
       <jsp:include   page="../include/baseTop.jsp"    flush="true">   
		      <jsp:param    name="open"    value="1"    />   
		</jsp:include>
 
 

<% if(r==null){ %> 

<form action="<%=path %>/membercenter1/upgrade/apply.jsp" method="get" name="selecFrom">

<div style=" text-align:center; height:30px; margin-top:70px;">你是<span style="color:#FF0000; font-weight:bold;">普通用户</span>，请选择要<span style="color:#FF0000; font-weight:bold;">升级的方式</span></div>
		<div style="width:60%; margin:0 auto; text-align:center;">
		<table width="100%" border="0">
		  <tr>
			<td><input name="FKTYPE" type="checkbox" id="checkdel" value="0" checked onClick="chooseOne(this);"/></td>
			<td>机构</td>
			<td><img src="<%=path %>/common1/images/sq/images/bigicon1.gif" width="95" height="88" /></td>
			<td><input name="FKTYPE" type="checkbox" id="checkdel2" value="1" onClick="chooseOne(this);"/></td>
			<td>专家</td>
			<td><img src="<%=path %>/common1/images/sq/images/bigicon2.gif" width="75" height="88"  /></td>
		  </tr>
		  <tr>
			<td height="100" colspan="6" align="center"><img style="cursor:pointer;" src="<%=path %>/common1/images/sq/images/nextbotton.gif" width="101" height="33" border="0" onclick="document.selecFrom.submit();"/></td>
		  </tr>
		</table>
		</div>
    </form>










<%}else{  
	  Record fkObj=(Record)r.getObjectValue("FK");
	  if("0".equals(r.getString("FKTYPE"))&&fkObj!=null){
		  String unitName=fkObj.getString("ITEM_9");
		  out.println("您已经是机构用户了，无法再升级，您的机构名称为："+unitName);
	  }else  if("1".equals(r.getString("FKTYPE"))&&fkObj!=null){
		  String unitName=fkObj.getString("ITEM_180");
		  out.println("您已经是专家用户了，无法再升级，您的姓名是："+unitName);
	  }else if(fkObj==null){
		  out.println("您的申请已经提交，请等待管理员的审核<br/>");
		  String cn="0".equals(r.getString("FKTYPE"))?"机构用户":"专家用户";
		  String cn1="0".equals(r.getString("FKTYPE"))?"机构名称：":"专家姓名：";
		  out.println("您申请的是"+cn+"，"+cn1+r.getString("APPLYNAME",""));
		  out.println();
	  }
	
} %>
</div>
  </div>
 <%@include file="../../common1/bottom.jsp"%>    
</body> 
</html>